import { Button, Form, Input, Popup, Switch } from 'antd-mobile'
import React, { useState } from 'react'
import List from './list';
import style from './Components/test.less'
import { useForm } from 'antd/es/form/Form';

export default function test () {
  const [visible,setVisible]=useState(false)
  const [form] = Form.useForm()
    const onFinish=(data:any)=>{
        console.log(data);
      
        
    }
  return (
  <>
    <Form
    form={form}
    onFinish={onFinish}>
      <Form.Item
      label="账号"
      name='account'>
        <Input placeholder='账号'/>
      </Form.Item>

      <Form.Item
      label="密码"
      name='password'>
        <Input placeholder='密码'/>
      </Form.Item>
      <Button onClick={()=>{form.setFieldValue('account','aaaaaaaaaa')}}>22222222222222222222222222222222</Button>
    </Form>
{/* <Button onClick={()=>{setVisible(true)}} >1111111111111111111</Button> */}
    {/* <Popup
                        bodyStyle={{ height: '100vh' }}
                        visible={visible}
                        onMaskClick={() => {
                            setVisible(false);
                        }}



                    >
                        {<div className={style.modal}>
                            <List showSearch={true} />
                            <div >
                                <Button block color='success' size='large' onClick={() => setVisible(false)}>
                                    确定
                                </Button>
                            </div>
                        </div>}
                    </Popup> */}

    </>
  )
}
